package com.bl.amsvisible.control;

import com.bl.amsvisible.pojo.testData;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

@RestController
public class testDataController {

    @ResponseBody
    @RequestMapping("/testData")
    public Object testDate(){
        List<testData> lists=new ArrayList<>();
        testData t1=new testData();
        t1.setDataName("温度");
        t1.setDataNum(new int[]{22,85,47,36,14,51});
        testData t2=new testData();
        t2.setDataName("湿度");
        t2.setDataNum(new int[]{22,25,47,84,31,66});

        lists.add(t1);
        lists.add(t2);
        return lists;
    }

}
